.class public Lcom/glympse/platform/Platform;
.super Lcom/glympse/platform/common/PlatformBase;
.source "Platform.java"


# annotations
.annotation system Ldalvik/annotation/MemberClasses;
    value = {
        Lcom/glympse/platform/Platform$BatteryBroadcastReceiver;,
        Lcom/glympse/platform/Platform$GToast;,
        Lcom/glympse/platform/Platform$SmsBroadcastReceiver;
    }
.end annotation


# static fields
.field public static final BETA:Z = false

.field public static final BUILD_AMAZON:Z = false

.field public static final BUILD_DATE:Ljava/lang/String; = "04/08/2011"

.field public static final BUILD_GETJAR:Z = false

.field public static final BUILD_NAME:Ljava/lang/String; = "as"

.field public static final BUILD_SAMSUNG:Z = false

.field public static final BUILD_TYPE:Ljava/lang/String; = "Android"

.field public static final BUILD_VCAST:Z = false

.field public static final BUILD_VODAFONE:Z = false

.field public static final GLYMPSE_BUILD:I = 0x82

.field public static final GLYMPSE_VERSION:Ljava/lang/String; = "1.28"

.field public static final SUPPORT_TAG:Ljava/lang/String; = "md_android"

.field public static final TAG:Ljava/lang/String; = "Glympse"

.field public static m_oContext:Landroid/content/Context;

.field protected static ms_oThis:Lcom/glympse/platform/Platform;

.field private static ms_strOsVer:Ljava/lang/String;


# instance fields
.field private m_oBatteryBroadcastReceiver:Lcom/glympse/platform/Platform$BatteryBroadcastReceiver;

.field private m_oHandler:Landroid/os/Handler;

.field private m_oSmsReceiver:Lcom/glympse/platform/SmsReceiver;


# direct methods
.method static constructor <clinit>()V
    .locals 1

    .prologue
    const/4 v0, 0x0

    .line 68
    sput-object v0, Lcom/glympse/platform/Platform;->ms_oThis:Lcom/glympse/platform/Platform;

    .line 94
    sput-object v0, Lcom/glympse/platform/Platform;->m_oContext:Landroid/content/Context;

    .line 102
    sput-object v0, Lcom/glympse/platform/Platform;->ms_strOsVer:Ljava/lang/String;

    .line 66
    return-void
.end method

.method public constructor <init>(Landroid/content/Context;Z)V
    .locals 2
    .parameter "oContext"
    .parameter "fActive"

    .prologue
    const/4 v1, 0x0

    .line 107
    invoke-direct {p0, p2}, Lcom/glympse/platform/common/PlatformBase;-><init>(Z)V

    .line 95
    new-instance v0, Landroid/os/Handler;

    invoke-direct {v0}, Landroid/os/Handler;-><init>()V

    iput-object v0, p0, Lcom/glympse/platform/Platform;->m_oHandler:Landroid/os/Handler;

    .line 97
    iput-object v1, p0, Lcom/glympse/platform/Platform;->m_oSmsReceiver:Lcom/glympse/platform/SmsReceiver;

    .line 98
    iput-object v1, p0, Lcom/glympse/platform/Platform;->m_oBatteryBroadcastReceiver:Lcom/glympse/platform/Platform$BatteryBroadcastReceiver;

    .line 110
    sput-object p0, Lcom/glympse/platform/Platform;->ms_oThis:Lcom/glympse/platform/Platform;

    .line 113
    sput-object p1, Lcom/glympse/platform/Platform;->m_oContext:Landroid/content/Context;

    .line 116
    new-instance v0, Lcom/glympse/platform/Platform$BatteryBroadcastReceiver;

    invoke-direct {v0, p0}, Lcom/glympse/platform/Platform$BatteryBroadcastReceiver;-><init>(Lcom/glympse/platform/Platform;)V

    iput-object v0, p0, Lcom/glympse/platform/Platform;->m_oBatteryBroadcastReceiver:Lcom/glympse/platform/Platform$BatteryBroadcastReceiver;

    .line 147
    invoke-virtual {p0}, Lcom/glympse/platform/Platform;->Start()V

    .line 150
    invoke-virtual {p0}, Lcom/glympse/platform/Platform;->CheckForOldTwitterAuth()V

    .line 151
    invoke-virtual {p0}, Lcom/glympse/platform/Platform;->CheckForOldFacebookAuth()V

    .line 161
    return-void
.end method

.method public static ByteArrayToString([B)Ljava/lang/String;
    .locals 3
    .parameter "ab"

    .prologue
    .line 680
    if-eqz p0, :cond_0

    array-length v1, p0

    if-lez v1, :cond_0

    .line 684
    :try_start_0
    new-instance v1, Ljava/lang/String;

    const-string v2, "UTF-8"

    invoke-direct {v1, p0, v2}, Ljava/lang/String;-><init>([BLjava/lang/String;)V
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    .line 691
    :goto_0
    return-object v1

    .line 686
    :catch_0
    move-exception v1

    move-object v0, v1

    .line 688
    .local v0, e:Ljava/lang/Exception;
    invoke-static {v0}, Lcom/glympse/platform/common/Helpers;->Log(Ljava/lang/Throwable;)V

    .line 691
    .end local v0           #e:Ljava/lang/Exception;
    :cond_0
    const-string v1, ""

    goto :goto_0
.end method

.method public static CalculateHMACSHA1(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
    .locals 8
    .parameter "strData"
    .parameter "strKey"

    .prologue
    .line 638
    const-string v0, "HmacSHA1"

    .line 640
    .local v0, HMAC_SHA1_ALGORITHM:Ljava/lang/String;
    const/4 v5, 0x0

    .line 644
    .local v5, strResult:Ljava/lang/String;
    :try_start_0
    new-instance v4, Ljavax/crypto/spec/SecretKeySpec;

    const-string v6, "UTF-8"

    invoke-virtual {p1, v6}, Ljava/lang/String;->getBytes(Ljava/lang/String;)[B

    move-result-object v6

    const-string v7, "HmacSHA1"

    invoke-direct {v4, v6, v7}, Ljavax/crypto/spec/SecretKeySpec;-><init>([BLjava/lang/String;)V

    .line 647
    .local v4, oSecretKeySpec:Ljavax/crypto/spec/SecretKeySpec;
    const-string v6, "HmacSHA1"

    invoke-static {v6}, Ljavax/crypto/Mac;->getInstance(Ljava/lang/String;)Ljavax/crypto/Mac;

    move-result-object v3

    .line 648
    .local v3, oMac:Ljavax/crypto/Mac;
    invoke-virtual {v3, v4}, Ljavax/crypto/Mac;->init(Ljava/security/Key;)V

    .line 651
    const-string v6, "UTF-8"

    invoke-virtual {p0, v6}, Ljava/lang/String;->getBytes(Ljava/lang/String;)[B

    move-result-object v6

    invoke-virtual {v3, v6}, Ljavax/crypto/Mac;->doFinal([B)[B

    move-result-object v1

    .line 654
    .local v1, abHMAC:[B
    invoke-static {v1}, Lcom/glympse/platform/common/Helpers;->Base64Encode([B)Ljava/lang/String;
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    move-result-object v5

    .line 660
    .end local v1           #abHMAC:[B
    .end local v3           #oMac:Ljavax/crypto/Mac;
    .end local v4           #oSecretKeySpec:Ljavax/crypto/spec/SecretKeySpec;
    :goto_0
    return-object v5

    .line 656
    :catch_0
    move-exception v6

    move-object v2, v6

    .line 658
    .local v2, e:Ljava/lang/Exception;
    invoke-static {v2}, Lcom/glympse/platform/Platform;->Log(Ljava/lang/Throwable;)V

    goto :goto_0
.end method

.method public static FormatDate(Landroid/content/Context;JJ)Ljava/lang/String;
    .locals 4
    .parameter "oContext"
    .parameter "lTimeFormatUTC"
    .parameter "lTimeCurrentUTC"

    .prologue
    .line 387
    const-wide/16 v0, 0x0

    cmp-long v0, v0, p3

    if-nez v0, :cond_0

    .line 389
    invoke-static {}, Lcom/glympse/platform/common/CorrectedTime;->GetTime()J

    move-result-wide p3

    .line 391
    :cond_0
    invoke-static {}, Ljava/util/TimeZone;->getDefault()Ljava/util/TimeZone;

    move-result-object v0

    invoke-virtual {v0, p1, p2}, Ljava/util/TimeZone;->getOffset(J)I

    move-result v0

    int-to-long v0, v0

    add-long/2addr v0, p1

    .line 392
    .local v0, lTimeFormatLocal:J
    invoke-static {}, Ljava/util/TimeZone;->getDefault()Ljava/util/TimeZone;

    move-result-object v2

    invoke-virtual {v2, p3, p4}, Ljava/util/TimeZone;->getOffset(J)I

    move-result v2

    int-to-long v2, v2

    add-long/2addr p3, v2

    .line 395
    .local p3, lTimeCurrentLocal:J
    const-wide/32 v2, 0x5265c00

    div-long/2addr v0, v2

    .end local v0           #lTimeFormatLocal:J
    long-to-int v0, v0

    .line 396
    .local v0, nDayFormat:I
    const-wide/32 v1, 0x5265c00

    div-long/2addr p3, v1

    .end local p3           #lTimeCurrentLocal:J
    long-to-int p3, p3

    .line 398
    .local p3, nDayCurrent:I
    new-instance p4, Ljava/util/Date;

    invoke-direct {p4, p1, p2}, Ljava/util/Date;-><init>(J)V

    .line 400
    .local p4, oDate:Ljava/util/Date;
    const/4 p1, 0x0

    .line 401
    .local p1, strDate:Ljava/lang/String;
    if-ne v0, p3, :cond_1

    .line 403
    const-string p1, "Today"

    .line 418
    :goto_0
    new-instance p2, Ljava/lang/StringBuilder;

    invoke-static {p1}, Ljava/lang/String;->valueOf(Ljava/lang/Object;)Ljava/lang/String;

    move-result-object p1

    .end local p1           #strDate:Ljava/lang/String;
    invoke-direct {p2, p1}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    const-string p1, " - "

    invoke-virtual {p2, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object p1

    invoke-static {p0}, Landroid/text/format/DateFormat;->getTimeFormat(Landroid/content/Context;)Ljava/text/DateFormat;

    move-result-object p0

    .end local p0
    invoke-virtual {p0, p4}, Ljava/text/DateFormat;->format(Ljava/util/Date;)Ljava/lang/String;

    move-result-object p0

    invoke-virtual {p1, p0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object p0

    invoke-virtual {p0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p0

    return-object p0

    .line 405
    .restart local p0
    .restart local p1       #strDate:Ljava/lang/String;
    :cond_1
    const/4 p1, 0x1

    sub-int p1, p3, p1

    if-ne v0, p1, :cond_2

    .line 407
    .end local p1           #strDate:Ljava/lang/String;
    const-string p1, "Yesterday"

    .restart local p1       #strDate:Ljava/lang/String;
    goto :goto_0

    .line 409
    .end local p1           #strDate:Ljava/lang/String;
    :cond_2
    const/4 p1, 0x7

    sub-int p1, p3, p1

    if-le v0, p1, :cond_3

    const/4 p1, 0x1

    sub-int p1, p3, p1

    if-ge v0, p1, :cond_3

    .line 411
    new-instance p1, Ljava/text/SimpleDateFormat;

    const-string p2, "EEEE"

    invoke-direct {p1, p2}, Ljava/text/SimpleDateFormat;-><init>(Ljava/lang/String;)V

    invoke-virtual {p1, p4}, Ljava/text/SimpleDateFormat;->format(Ljava/util/Date;)Ljava/lang/String;

    move-result-object p1

    .restart local p1       #strDate:Ljava/lang/String;
    goto :goto_0

    .line 415
    .end local p1           #strDate:Ljava/lang/String;
    :cond_3
    invoke-static {p0}, Landroid/text/format/DateFormat;->getDateFormat(Landroid/content/Context;)Ljava/text/DateFormat;

    move-result-object p1

    invoke-virtual {p1, p4}, Ljava/text/DateFormat;->format(Ljava/util/Date;)Ljava/lang/String;

    move-result-object p1

    .restart local p1       #strDate:Ljava/lang/String;
    goto :goto_0
.end method

.method public static GetDateTimeString()Ljava/lang/String;
    .locals 5

    .prologue
    .line 374
    :try_start_0
    new-instance v1, Ljava/text/SimpleDateFormat;

    const-string v2, "yyyy-MM-dd HH:mm:ssZ"

    invoke-direct {v1, v2}, Ljava/text/SimpleDateFormat;-><init>(Ljava/lang/String;)V

    new-instance v2, Ljava/util/Date;

    invoke-static {}, Lcom/glympse/platform/common/CorrectedTime;->GetTime()J

    move-result-wide v3

    invoke-direct {v2, v3, v4}, Ljava/util/Date;-><init>(J)V

    invoke-virtual {v1, v2}, Ljava/text/SimpleDateFormat;->format(Ljava/util/Date;)Ljava/lang/String;
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    move-result-object v1

    .line 380
    :goto_0
    return-object v1

    .line 376
    :catch_0
    move-exception v1

    move-object v0, v1

    .line 378
    .local v0, e:Ljava/lang/Exception;
    invoke-static {v0}, Lcom/glympse/platform/common/Helpers;->Log(Ljava/lang/Throwable;)V

    .line 380
    const/4 v1, 0x0

    goto :goto_0
.end method

.method public static GetDefaultMetric()Z
    .locals 3

    .prologue
    .line 551
    invoke-static {}, Ljava/util/Locale;->getDefault()Ljava/util/Locale;

    move-result-object v0

    .line 552
    .local v0, oLocale:Ljava/util/Locale;
    if-nez v0, :cond_1

    const/4 v2, 0x0

    move-object v1, v2

    .line 555
    .local v1, strCode:Ljava/lang/String;
    :goto_0
    invoke-static {v1}, Lcom/glympse/platform/common/Helpers;->IsEmpty(Ljava/lang/String;)Z

    move-result v2

    if-nez v2, :cond_0

    .line 556
    const-string v2, "US"

    invoke-virtual {v1, v2}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v2

    if-nez v2, :cond_0

    .line 557
    const-string v2, "MM"

    invoke-virtual {v1, v2}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v2

    if-nez v2, :cond_0

    .line 558
    const-string v2, "LR"

    invoke-virtual {v1, v2}, Ljava/lang/String;->equalsIgnoreCase(Ljava/lang/String;)Z

    move-result v2

    if-eqz v2, :cond_2

    .line 560
    :cond_0
    const/4 v2, 0x0

    .line 564
    :goto_1
    return v2

    .line 552
    .end local v1           #strCode:Ljava/lang/String;
    :cond_1
    invoke-virtual {v0}, Ljava/util/Locale;->getCountry()Ljava/lang/String;

    move-result-object v2

    move-object v1, v2

    goto :goto_0

    .line 564
    .restart local v1       #strCode:Ljava/lang/String;
    :cond_2
    const/4 v2, 0x1

    goto :goto_1
.end method

.method public static GetDeviceInfo()Ljava/lang/String;
    .locals 2

    .prologue
    .line 359
    const/4 v0, 0x0

    invoke-static {v0}, Lcom/glympse/android/glympseservice/ErrorReporter;->CaptureDeviceInfo(Landroid/content/Context;)V

    .line 360
    new-instance v0, Ljava/lang/StringBuilder;

    const-string v1, "Brand: ["

    invoke-direct {v0, v1}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    sget-object v1, Landroid/os/Build;->BRAND:Ljava/lang/String;

    invoke-static {v1}, Lcom/glympse/platform/common/Helpers;->SafeStr(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    .line 361
    const-string v1, "], Model: ["

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    sget-object v1, Landroid/os/Build;->MODEL:Ljava/lang/String;

    invoke-static {v1}, Lcom/glympse/platform/common/Helpers;->SafeStr(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    .line 362
    const-string v1, "], Type: ["

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    sget-object v1, Lcom/glympse/android/glympseservice/ErrorReporter;->ms_strPhoneType:Ljava/lang/String;

    invoke-static {v1}, Lcom/glympse/platform/common/Helpers;->SafeStr(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    .line 363
    const-string v1, "], Network: ["

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    sget-object v1, Lcom/glympse/android/glympseservice/ErrorReporter;->ms_strNetworkType:Ljava/lang/String;

    invoke-static {v1}, Lcom/glympse/platform/common/Helpers;->SafeStr(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    .line 364
    const-string v1, "], SIM: ["

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    sget-object v1, Lcom/glympse/android/glympseservice/ErrorReporter;->ms_strSimState:Ljava/lang/String;

    invoke-static {v1}, Lcom/glympse/platform/common/Helpers;->SafeStr(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    .line 365
    const-string v1, "], Operator: ["

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    sget-object v1, Lcom/glympse/android/glympseservice/ErrorReporter;->ms_strSimOperatorName:Ljava/lang/String;

    invoke-static {v1}, Lcom/glympse/platform/common/Helpers;->SafeStr(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    .line 366
    const-string v1, "]"

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v0

    .line 360
    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    return-object v0
.end method

.method public static GetLanguageCode()Ljava/lang/String;
    .locals 2

    .prologue
    .line 543
    invoke-static {}, Ljava/util/Locale;->getDefault()Ljava/util/Locale;

    move-result-object v0

    .line 544
    .local v0, oLocale:Ljava/util/Locale;
    if-nez v0, :cond_0

    const/4 v1, 0x0

    :goto_0
    return-object v1

    :cond_0
    invoke-virtual {v0}, Ljava/util/Locale;->getLanguage()Ljava/lang/String;

    move-result-object v1

    goto :goto_0
.end method

.method public static GetOsVer()Ljava/lang/String;
    .locals 4

    .prologue
    .line 334
    sget-object v3, Lcom/glympse/platform/Platform;->ms_strOsVer:Ljava/lang/String;

    if-nez v3, :cond_0

    .line 337
    new-instance v2, Ljava/lang/StringBuilder;

    sget-object v3, Landroid/os/Build$VERSION;->RELEASE:Ljava/lang/String;

    invoke-virtual {v3}, Ljava/lang/String;->length()I

    move-result v3

    invoke-direct {v2, v3}, Ljava/lang/StringBuilder;-><init>(I)V

    .line 338
    .local v2, strbld:Ljava/lang/StringBuilder;
    const/4 v1, 0x0

    .local v1, i:I
    :goto_0
    sget-object v3, Landroid/os/Build$VERSION;->RELEASE:Ljava/lang/String;

    invoke-virtual {v3}, Ljava/lang/String;->length()I

    move-result v3

    if-lt v1, v3, :cond_1

    .line 351
    invoke-virtual {v2}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v3

    sput-object v3, Lcom/glympse/platform/Platform;->ms_strOsVer:Ljava/lang/String;

    .line 353
    .end local v1           #i:I
    .end local v2           #strbld:Ljava/lang/StringBuilder;
    :cond_0
    sget-object v3, Lcom/glympse/platform/Platform;->ms_strOsVer:Ljava/lang/String;

    return-object v3

    .line 341
    .restart local v1       #i:I
    .restart local v2       #strbld:Ljava/lang/StringBuilder;
    :cond_1
    sget-object v3, Landroid/os/Build$VERSION;->RELEASE:Ljava/lang/String;

    invoke-virtual {v3, v1}, Ljava/lang/String;->charAt(I)C

    move-result v0

    .line 344
    .local v0, c:C
    const/16 v3, 0x61

    if-lt v0, v3, :cond_2

    const/16 v3, 0x7a

    if-le v0, v3, :cond_5

    :cond_2
    const/16 v3, 0x41

    if-lt v0, v3, :cond_3

    const/16 v3, 0x5a

    if-le v0, v3, :cond_5

    :cond_3
    const/16 v3, 0x30

    if-lt v0, v3, :cond_4

    const/16 v3, 0x39

    if-le v0, v3, :cond_5

    .line 345
    :cond_4
    const/16 v3, 0x2e

    if-eq v3, v0, :cond_5

    const/16 v3, 0x2d

    if-eq v3, v0, :cond_5

    const/16 v3, 0x5f

    if-eq v3, v0, :cond_5

    const/16 v3, 0x28

    if-eq v3, v0, :cond_5

    const/16 v3, 0x29

    if-eq v3, v0, :cond_5

    const/16 v3, 0x7c

    if-eq v3, v0, :cond_5

    const/16 v3, 0x20

    if-ne v3, v0, :cond_6

    .line 347
    :cond_5
    invoke-virtual {v2, v0}, Ljava/lang/StringBuilder;->append(C)Ljava/lang/StringBuilder;

    .line 338
    :cond_6
    add-int/lit8 v1, v1, 0x1

    goto :goto_0
.end method

.method public static GetTelephonyManagerCallStateString(I)Ljava/lang/String;
    .locals 1
    .parameter "eCallState"

    .prologue
    .line 1523
    packed-switch p0, :pswitch_data_0

    .line 1529
    invoke-static {p0}, Ljava/lang/Integer;->toString(I)Ljava/lang/String;

    move-result-object v0

    :goto_0
    return-object v0

    .line 1525
    :pswitch_0
    const-string v0, "IDLE"

    goto :goto_0

    .line 1526
    :pswitch_1
    const-string v0, "RINGING"

    goto :goto_0

    .line 1527
    :pswitch_2
    const-string v0, "OFFHOOK"

    goto :goto_0

    .line 1523
    nop

    :pswitch_data_0
    .packed-switch 0x0
        :pswitch_0
        :pswitch_1
        :pswitch_2
    .end packed-switch
.end method

.method public static GetTelephonyManagerDataActivityString(I)Ljava/lang/String;
    .locals 1
    .parameter "eDataActivity"

    .prologue
    .line 1535
    packed-switch p0, :pswitch_data_0

    .line 1543
    invoke-static {p0}, Ljava/lang/Integer;->toString(I)Ljava/lang/String;

    move-result-object v0

    :goto_0
    return-object v0

    .line 1537
    :pswitch_0
    const-string v0, "DATA_ACTIVITY_NONE"

    goto :goto_0

    .line 1538
    :pswitch_1
    const-string v0, "DATA_ACTIVITY_IN"

    goto :goto_0

    .line 1539
    :pswitch_2
    const-string v0, "DATA_ACTIVITY_OUT"

    goto :goto_0

    .line 1540
    :pswitch_3
    const-string v0, "DATA_ACTIVITY_INOUT"

    goto :goto_0

    .line 1541
    :pswitch_4
    const-string v0, "DATA_ACTIVITY_DORMANT"

    goto :goto_0

    .line 1535
    nop

    :pswitch_data_0
    .packed-switch 0x0
        :pswitch_0
        :pswitch_1
        :pswitch_2
        :pswitch_3
        :pswitch_4
    .end packed-switch
.end method

.method public static GetTelephonyManagerDataConnectionStateString(I)Ljava/lang/String;
    .locals 1
    .parameter "eDataState"

    .prologue
    .line 1549
    packed-switch p0, :pswitch_data_0

    .line 1556
    invoke-static {p0}, Ljava/lang/Integer;->toString(I)Ljava/lang/String;

    move-result-object v0

    :goto_0
    return-object v0

    .line 1551
    :pswitch_0
    const-string v0, "DATA_DISCONNECTED"

    goto :goto_0

    .line 1552
    :pswitch_1
    const-string v0, "DATA_CONNECTING"

    goto :goto_0

    .line 1553
    :pswitch_2
    const-string v0, "DATA_CONNECTED"

    goto :goto_0

    .line 1554
    :pswitch_3
    const-string v0, "DATA_SUSPENDED"

    goto :goto_0

    .line 1549
    :pswitch_data_0
    .packed-switch 0x0
        :pswitch_0
        :pswitch_1
        :pswitch_2
        :pswitch_3
    .end packed-switch
.end method

.method public static GetTelephonyManagerNetworkTypeString(I)Ljava/lang/String;
    .locals 1
    .parameter "eNetworkType"

    .prologue
    .line 1484
    packed-switch p0, :pswitch_data_0

    .line 1502
    invoke-static {p0}, Ljava/lang/Integer;->toString(I)Ljava/lang/String;

    move-result-object v0

    :goto_0
    return-object v0

    .line 1486
    :pswitch_0
    const-string v0, "UNKNOWN"

    goto :goto_0

    .line 1487
    :pswitch_1
    const-string v0, "GPRS"

    goto :goto_0

    .line 1488
    :pswitch_2
    const-string v0, "EDGE"

    goto :goto_0

    .line 1489
    :pswitch_3
    const-string v0, "UMTS"

    goto :goto_0

    .line 1490
    :pswitch_4
    const-string v0, "CDMA"

    goto :goto_0

    .line 1491
    :pswitch_5
    const-string v0, "EVDO_0"

    goto :goto_0

    .line 1492
    :pswitch_6
    const-string v0, "EVDO_A"

    goto :goto_0

    .line 1493
    :pswitch_7
    const-string v0, "1xRTT"

    goto :goto_0

    .line 1494
    :pswitch_8
    const-string v0, "HSDPA"

    goto :goto_0

    .line 1495
    :pswitch_9
    const-string v0, "HSUPA"

    goto :goto_0

    .line 1496
    :pswitch_a
    const-string v0, "HSPA"

    goto :goto_0

    .line 1497
    :pswitch_b
    const-string v0, "IDEN"

    goto :goto_0

    .line 1498
    :pswitch_c
    const-string v0, "EVDO_B"

    goto :goto_0

    .line 1499
    :pswitch_d
    const-string v0, "LTE"

    goto :goto_0

    .line 1500
    :pswitch_e
    const-string v0, "EHRPD"

    goto :goto_0

    .line 1484
    nop

    :pswitch_data_0
    .packed-switch 0x0
        :pswitch_0
        :pswitch_1
        :pswitch_2
        :pswitch_3
        :pswitch_4
        :pswitch_5
        :pswitch_6
        :pswitch_7
        :pswitch_8
        :pswitch_9
        :pswitch_a
        :pswitch_b
        :pswitch_c
        :pswitch_d
        :pswitch_e
    .end packed-switch
.end method

.method public static GetTelephonyManagerPhoneTypeString(I)Ljava/lang/String;
    .locals 1
    .parameter "ePhoneType"

    .prologue
    .line 1471
    packed-switch p0, :pswitch_data_0

    .line 1478
    invoke-static {p0}, Ljava/lang/Integer;->toString(I)Ljava/lang/String;

    move-result-object v0

    :goto_0
    return-object v0

    .line 1473
    :pswitch_0
    const-string v0, "None"

    goto :goto_0

    .line 1474
    :pswitch_1
    const-string v0, "GSM"

    goto :goto_0

    .line 1475
    :pswitch_2
    const-string v0, "CDMA"

    goto :goto_0

    .line 1476
    :pswitch_3
    const-string v0, "SIP"

    goto :goto_0

    .line 1471
    :pswitch_data_0
    .packed-switch 0x0
        :pswitch_0
        :pswitch_1
        :pswitch_2
        :pswitch_3
    .end packed-switch
.end method

.method public static GetTelephonyManagerSimStateString(I)Ljava/lang/String;
    .locals 1
    .parameter "eSimState"

    .prologue
    .line 1508
    packed-switch p0, :pswitch_data_0

    .line 1517
    invoke-static {p0}, Ljava/lang/Integer;->toString(I)Ljava/lang/String;

    move-result-object v0

    :goto_0
    return-object v0

    .line 1510
    :pswitch_0
    const-string v0, "UNKNOWN"

    goto :goto_0

    .line 1511
    :pswitch_1
    const-string v0, "ABSENT"

    goto :goto_0

    .line 1512
    :pswitch_2
    const-string v0, "PIN_REQUIRED"

    goto :goto_0

    .line 1513
    :pswitch_3
    const-string v0, "PUK_REQUIRED"

    goto :goto_0

    .line 1514
    :pswitch_4
    const-string v0, "NETWORK_LOCKED"

    goto :goto_0

    .line 1515
    :pswitch_5
    const-string v0, "READY"

    goto :goto_0

    .line 1508
    :pswitch_data_0
    .packed-switch 0x0
        :pswitch_0
        :pswitch_1
        :pswitch_2
        :pswitch_3
        :pswitch_4
        :pswitch_5
    .end packed-switch
.end method

.method public static GetThreadId()J
    .locals 2

    .prologue
    .line 327
    invoke-static {}, Ljava/lang/Thread;->currentThread()Ljava/lang/Thread;

    move-result-object v0

    invoke-virtual {v0}, Ljava/lang/Thread;->getId()J

    move-result-wide v0

    return-wide v0
.end method

.method public static IsUTF7(Ljava/lang/String;)Z
    .locals 4
    .parameter "str"

    .prologue
    const/4 v3, 0x0

    .line 668
    :try_start_0
    const-string v1, "UTF-7"

    invoke-virtual {p0, v1}, Ljava/lang/String;->getBytes(Ljava/lang/String;)[B

    move-result-object v1

    array-length v1, v1

    invoke-virtual {p0}, Ljava/lang/String;->length()I
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    move-result v2

    if-ne v1, v2, :cond_0

    const/4 v1, 0x1

    .line 674
    :goto_0
    return v1

    :cond_0
    move v1, v3

    .line 668
    goto :goto_0

    .line 670
    :catch_0
    move-exception v1

    move-object v0, v1

    .line 672
    .local v0, e:Ljava/lang/Exception;
    invoke-static {v0}, Lcom/glympse/platform/common/Helpers;->Log(Ljava/lang/Throwable;)V

    move v1, v3

    .line 674
    goto :goto_0
.end method

.method public static declared-synchronized Log(Ljava/lang/String;)V
    .locals 2
    .parameter "strLog"

    .prologue
    .line 249
    const-class v0, Lcom/glympse/platform/Platform;

    monitor-enter v0

    const/4 v1, 0x0

    :try_start_0
    invoke-static {v1, p0}, Lcom/glympse/platform/Platform;->Log(ZLjava/lang/String;)V
    :try_end_0
    .catchall {:try_start_0 .. :try_end_0} :catchall_0

    .line 250
    monitor-exit v0

    return-void

    .line 249
    :catchall_0
    move-exception v1

    monitor-exit v0

    throw v1
.end method

.method public static declared-synchronized Log(Ljava/lang/Throwable;)V
    .locals 4
    .parameter "e"

    .prologue
    .line 315
    const-class v0, Lcom/glympse/platform/Platform;

    monitor-enter v0

    if-eqz p0, :cond_0

    .line 317
    const/4 v1, 0x1

    .line 318
    :try_start_0
    new-instance v2, Ljava/lang/StringBuilder;

    const-string v3, "################################################################################\n"

    invoke-direct {v2, v3}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    .line 319
    invoke-static {p0}, Landroid/util/Log;->getStackTraceString(Ljava/lang/Throwable;)Ljava/lang/String;

    move-result-object v3

    invoke-virtual {v2, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v2

    .line 320
    const-string v3, "################################################################################"

    invoke-virtual {v2, v3}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v2

    .line 318
    invoke-virtual {v2}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v2

    .line 317
    invoke-static {v1, v2}, Lcom/glympse/platform/Platform;->Log(ZLjava/lang/String;)V
    :try_end_0
    .catchall {:try_start_0 .. :try_end_0} :catchall_0

    .line 322
    :cond_0
    monitor-exit v0

    return-void

    .line 315
    :catchall_0
    move-exception v1

    monitor-exit v0

    throw v1
.end method

.method public static declared-synchronized Log(ZLjava/lang/String;)V
    .locals 8
    .parameter "fError"
    .parameter "strLog"

    .prologue
    .line 255
    const-class v3, Lcom/glympse/platform/Platform;

    monitor-enter v3

    const-wide/16 v0, 0x0

    .line 257
    .local v0, lCurrent:J
    :try_start_0
    const-string v4, "\n"

    invoke-virtual {p1, v4}, Ljava/lang/String;->split(Ljava/lang/String;)[Ljava/lang/String;

    move-result-object v4

    array-length v5, v4
    :try_end_0
    .catchall {:try_start_0 .. :try_end_0} :catchall_0

    const/4 v6, 0x0

    :goto_0
    if-lt v6, v5, :cond_0

    .line 310
    monitor-exit v3

    return-void

    .line 257
    :cond_0
    :try_start_1
    aget-object v2, v4, v6

    .line 259
    .local v2, str:Ljava/lang/String;
    invoke-static {v2}, Lcom/glympse/platform/common/Helpers;->IsEmpty(Ljava/lang/String;)Z
    :try_end_1
    .catchall {:try_start_1 .. :try_end_1} :catchall_0

    move-result v7

    if-nez v7, :cond_1

    .line 257
    :cond_1
    add-int/lit8 v6, v6, 0x1

    goto :goto_0

    .line 255
    .end local v2           #str:Ljava/lang/String;
    :catchall_0
    move-exception v4

    monitor-exit v3

    throw v4
.end method

.method public static OAuthEncode(Ljava/lang/String;)Ljava/lang/String;
    .locals 7
    .parameter "str"

    .prologue
    const/16 v6, 0x30

    .line 590
    invoke-static {p0}, Lcom/glympse/platform/common/Helpers;->IsEmpty(Ljava/lang/String;)Z

    move-result v4

    if-eqz v4, :cond_0

    .line 592
    const-string v4, ""

    .line 632
    :goto_0
    return-object v4

    .line 598
    :cond_0
    new-instance v3, Ljava/lang/StringBuffer;

    invoke-virtual {p0}, Ljava/lang/String;->length()I

    move-result v4

    invoke-direct {v3, v4}, Ljava/lang/StringBuffer;-><init>(I)V

    .line 601
    .local v3, strbuf:Ljava/lang/StringBuffer;
    const/4 v1, 0x0

    .local v1, nChar:I
    :goto_1
    invoke-virtual {p0}, Ljava/lang/String;->length()I

    move-result v4

    if-lt v1, v4, :cond_1

    .line 632
    invoke-virtual {v3}, Ljava/lang/StringBuffer;->toString()Ljava/lang/String;

    move-result-object v4

    goto :goto_0

    .line 604
    :cond_1
    invoke-virtual {p0, v1}, Ljava/lang/String;->charAt(I)C

    move-result v0

    .line 607
    .local v0, cChar:C
    const/16 v4, 0x41

    if-lt v0, v4, :cond_2

    const/16 v4, 0x5a

    if-le v0, v4, :cond_5

    .line 608
    :cond_2
    const/16 v4, 0x61

    if-lt v0, v4, :cond_3

    const/16 v4, 0x7a

    if-le v0, v4, :cond_5

    .line 609
    :cond_3
    if-lt v0, v6, :cond_4

    const/16 v4, 0x39

    if-le v0, v4, :cond_5

    .line 610
    :cond_4
    const/16 v4, 0x2d

    if-eq v0, v4, :cond_5

    .line 611
    const/16 v4, 0x2e

    if-eq v0, v4, :cond_5

    .line 612
    const/16 v4, 0x5f

    if-eq v0, v4, :cond_5

    .line 613
    const/16 v4, 0x7e

    if-ne v0, v4, :cond_6

    .line 616
    :cond_5
    invoke-virtual {v3, v0}, Ljava/lang/StringBuffer;->append(C)Ljava/lang/StringBuffer;

    .line 601
    :goto_2
    add-int/lit8 v1, v1, 0x1

    goto :goto_1

    .line 622
    :cond_6
    const/16 v4, 0x25

    invoke-virtual {v3, v4}, Ljava/lang/StringBuffer;->append(C)Ljava/lang/StringBuffer;

    .line 623
    const/16 v4, 0x10

    invoke-static {v0, v4}, Ljava/lang/Integer;->toString(II)Ljava/lang/String;

    move-result-object v4

    invoke-virtual {v4}, Ljava/lang/String;->toUpperCase()Ljava/lang/String;

    move-result-object v2

    .line 624
    .local v2, strChar:Ljava/lang/String;
    invoke-virtual {v2}, Ljava/lang/String;->length()I

    move-result v4

    const/4 v5, 0x2

    if-ge v4, v5, :cond_7

    .line 626
    invoke-virtual {v3, v6}, Ljava/lang/StringBuffer;->append(C)Ljava/lang/StringBuffer;

    .line 628
    :cond_7
    invoke-virtual {v3, v2}, Ljava/lang/StringBuffer;->append(Ljava/lang/String;)Ljava/lang/StringBuffer;

    goto :goto_2
.end method

.method public static ParseMpt(Ljava/lang/String;)[Ljava/lang/String;
    .locals 3
    .parameter "strMpt"

    .prologue
    .line 873
    const-string v0, "("

    const-string v1, ""

    invoke-virtual {p0, v0, v1}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;

    move-result-object v0

    const-string v1, ")"

    const-string v2, ""

    invoke-virtual {v0, v1, v2}, Ljava/lang/String;->replace(Ljava/lang/CharSequence;Ljava/lang/CharSequence;)Ljava/lang/String;

    move-result-object v0

    const-string v1, ","

    invoke-virtual {v0, v1}, Ljava/lang/String;->split(Ljava/lang/String;)[Ljava/lang/String;

    move-result-object v0

    return-object v0
.end method

.method public static StringReplaceFirst(Ljava/lang/String;Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
    .locals 1
    .parameter "strSource"
    .parameter "strSearch"
    .parameter "strReplace"

    .prologue
    .line 879
    invoke-virtual {p0, p1, p2}, Ljava/lang/String;->replaceFirst(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;

    move-result-object v0

    return-object v0
.end method

.method public static UrlEncode(Ljava/lang/String;)Ljava/lang/String;
    .locals 2
    .parameter "str"

    .prologue
    .line 578
    :try_start_0
    const-string v1, "UTF-8"

    invoke-static {p0, v1}, Ljava/net/URLEncoder;->encode(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    move-result-object v1

    .line 584
    :goto_0
    return-object v1

    .line 580
    :catch_0
    move-exception v1

    move-object v0, v1

    .line 582
    .local v0, e:Ljava/lang/Exception;
    invoke-static {v0}, Lcom/glympse/platform/common/Helpers;->Log(Ljava/lang/Throwable;)V

    move-object v1, p0

    .line 584
    goto :goto_0
.end method

.method public static acos(D)D
    .locals 2
    .parameter "d"

    .prologue
    .line 1010
    invoke-static {p0, p1}, Ljava/lang/Math;->acos(D)D

    move-result-wide v0

    return-wide v0
.end method

.method public static instance()Lcom/glympse/platform/Platform;
    .locals 1

    .prologue
    .line 243
    sget-object v0, Lcom/glympse/platform/Platform;->ms_oThis:Lcom/glympse/platform/Platform;

    return-object v0
.end method


# virtual methods
.method public CancelPost(Lcom/glympse/platform/GRunnable;)V
    .locals 1
    .parameter "oRunnable"

    .prologue
    .line 867
    iget-object v0, p0, Lcom/glympse/platform/Platform;->m_oHandler:Landroid/os/Handler;

    invoke-virtual {v0, p1}, Landroid/os/Handler;->removeCallbacks(Ljava/lang/Runnable;)V

    .line 868
    return-void
.end method

.method public CheckForOldFacebookAuth()V
    .locals 6

    .prologue
    .line 900
    iget-object v3, p0, Lcom/glympse/platform/Platform;->m_oConfig:Lcom/glympse/platform/Config;

    iget-object v3, v3, Lcom/glympse/platform/Config;->m_strFacebookToken:Ljava/lang/String;

    invoke-static {v3}, Lcom/glympse/platform/common/Helpers;->IsEmpty(Ljava/lang/String;)Z

    move-result v3

    if-eqz v3, :cond_0

    iget-object v3, p0, Lcom/glympse/platform/Platform;->m_oConfig:Lcom/glympse/platform/Config;

    iget-object v3, v3, Lcom/glympse/platform/Config;->m_strFacebookName:Ljava/lang/String;

    invoke-static {v3}, Lcom/glympse/platform/common/Helpers;->IsEmpty(Ljava/lang/String;)Z

    move-result v3

    if-nez v3, :cond_0

    .line 903
    sget-object v3, Lcom/glympse/platform/Platform;->m_oContext:Landroid/content/Context;

    const-string v4, "FBSessionPreferences"

    const/4 v5, 0x0

    invoke-virtual {v3, v4, v5}, Landroid/content/Context;->getSharedPreferences(Ljava/lang/String;I)Landroid/content/SharedPreferences;

    move-result-object v1

    .line 904
    .local v1, oPrefs:Landroid/content/SharedPreferences;
    const-string v3, "FBSessionKey"

    const/4 v4, 0x0

    invoke-interface {v1, v3, v4}, Landroid/content/SharedPreferences;->getString(Ljava/lang/String;Ljava/lang/String;)Ljava/lang/String;

    move-result-object v2

    .line 907
    .local v2, strSessionKey:Ljava/lang/String;
    invoke-static {v2}, Lcom/glympse/platform/common/Helpers;->IsEmpty(Ljava/lang/String;)Z

    move-result v3

    if-nez v3, :cond_1

    .line 909
    iget-object v3, p0, Lcom/glympse/platform/Platform;->m_oJobQueue:Lcom/glympse/platform/common/JobQueue;

    new-instance v4, Lcom/glympse/platform/common/FacebookJobs$UpgradeSessionJob;

    invoke-direct {v4, v2}, Lcom/glympse/platform/common/FacebookJobs$UpgradeSessionJob;-><init>(Ljava/lang/String;)V

    invoke-virtual {v3, v4}, Lcom/glympse/platform/common/JobQueue;->AddJob(Lcom/glympse/platform/common/JobQueue$Job;)V

    .line 921
    :goto_0
    invoke-interface {v1}, Landroid/content/SharedPreferences;->edit()Landroid/content/SharedPreferences$Editor;

    move-result-object v0

    .line 922
    .local v0, oEditor:Landroid/content/SharedPreferences$Editor;
    const-string v3, "FBUserId"

    invoke-interface {v0, v3}, Landroid/content/SharedPreferences$Editor;->remove(Ljava/lang/String;)Landroid/content/SharedPreferences$Editor;

    .line 923
    const-string v3, "FBSessionKey"

    invoke-interface {v0, v3}, Landroid/content/SharedPreferences$Editor;->remove(Ljava/lang/String;)Landroid/content/SharedPreferences$Editor;

    .line 924
    const-string v3, "FBSessionSecret"

    invoke-interface {v0, v3}, Landroid/content/SharedPreferences$Editor;->remove(Ljava/lang/String;)Landroid/content/SharedPreferences$Editor;

    .line 925
    const-string v3, "FBSessionExpires"

    invoke-interface {v0, v3}, Landroid/content/SharedPreferences$Editor;->remove(Ljava/lang/String;)Landroid/content/SharedPreferences$Editor;

    .line 926
    invoke-interface {v0}, Landroid/content/SharedPreferences$Editor;->commit()Z

    .line 928
    .end local v0           #oEditor:Landroid/content/SharedPreferences$Editor;
    .end local v1           #oPrefs:Landroid/content/SharedPreferences;
    .end local v2           #strSessionKey:Ljava/lang/String;
    :cond_0
    return-void

    .line 917
    .restart local v1       #oPrefs:Landroid/content/SharedPreferences;
    .restart local v2       #strSessionKey:Ljava/lang/String;
    :cond_1
    iget-object v3, p0, Lcom/glympse/platform/Platform;->m_oConfig:Lcom/glympse/platform/Config;

    invoke-virtual {v3}, Lcom/glympse/platform/Config;->ClearFacebookCredentials()V

    goto :goto_0
.end method

.method public CheckForOldTwitterAuth()V
    .locals 5

    .prologue
    .line 887
    iget-object v0, p0, Lcom/glympse/platform/Platform;->m_oConfig:Lcom/glympse/platform/Config;

    invoke-virtual {v0}, Lcom/glympse/platform/Config;->HasTwitterCredentials()Z

    move-result v0

    if-nez v0, :cond_0

    .line 888
    iget-object v0, p0, Lcom/glympse/platform/Platform;->m_oConfig:Lcom/glympse/platform/Config;

    iget-object v0, v0, Lcom/glympse/platform/Config;->m_strTwitterPassword:Ljava/lang/String;

    invoke-static {v0}, Lcom/glympse/platform/common/Helpers;->IsEmpty(Ljava/lang/String;)Z

    move-result v0

    if-nez v0, :cond_0

    iget-object v0, p0, Lcom/glympse/platform/Platform;->m_oConfig:Lcom/glympse/platform/Config;

    iget-object v0, v0, Lcom/glympse/platform/Config;->m_strTwitterName:Ljava/lang/String;

    invoke-static {v0}, Lcom/glympse/platform/common/Helpers;->IsEmpty(Ljava/lang/String;)Z

    move-result v0

    if-nez v0, :cond_0

    .line 891
    iget-object v0, p0, Lcom/glympse/platform/Platform;->m_oJobQueue:Lcom/glympse/platform/common/JobQueue;

    new-instance v1, Lcom/glympse/platform/common/TwitterJobs$SignInJob;

    iget-object v2, p0, Lcom/glympse/platform/Platform;->m_oConfig:Lcom/glympse/platform/Config;

    iget-object v2, v2, Lcom/glympse/platform/Config;->m_strTwitterName:Ljava/lang/String;

    iget-object v3, p0, Lcom/glympse/platform/Platform;->m_oConfig:Lcom/glympse/platform/Config;

    iget-object v3, v3, Lcom/glympse/platform/Config;->m_strTwitterPassword:Ljava/lang/String;

    const/4 v4, 0x0

    invoke-direct {v1, v2, v3, v4}, Lcom/glympse/platform/common/TwitterJobs$SignInJob;-><init>(Ljava/lang/String;Ljava/lang/String;Lcom/glympse/platform/common/TwitterJobs$SignInCallback;)V

    invoke-virtual {v0, v1}, Lcom/glympse/platform/common/JobQueue;->AddJob(Lcom/glympse/platform/common/JobQueue$Job;)V

    .line 893
    :cond_0
    return-void
.end method

.method public Destroy()V
    .locals 2

    .prologue
    const/4 v1, 0x0

    .line 179
    const-string v0, "Platform::Destory"

    invoke-static {v0}, Lcom/glympse/platform/common/Helpers;->Log(Ljava/lang/String;)V

    .line 181
    invoke-virtual {p0}, Lcom/glympse/platform/Platform;->Stop()V

    .line 202
    sput-object v1, Lcom/glympse/platform/Platform;->m_oContext:Landroid/content/Context;

    .line 203
    sput-object v1, Lcom/glympse/platform/Platform;->ms_oThis:Lcom/glympse/platform/Platform;

    .line 204
    return-void
.end method

.method public DoesSupportSmsSending()Z
    .locals 10

    .prologue
    const/4 v9, 0x1

    .line 697
    sget-object v7, Lcom/glympse/android/glympseservice/GlympseService;->ms_oThis:Lcom/glympse/android/glympseservice/GlympseService;

    invoke-virtual {v7}, Lcom/glympse/android/glympseservice/GlympseService;->IsEmulator()Z

    move-result v5

    .line 698
    .local v5, fEmulator:Z
    invoke-virtual {p0}, Lcom/glympse/platform/Platform;->IsAirplaneMode()Z

    move-result v3

    .line 699
    .local v3, fAirplaneMode:Z
    const/4 v1, -0x1

    .line 700
    .local v1, ePhoneType:I
    const/4 v2, -0x1

    .line 705
    .local v2, eSimState:I
    :try_start_0
    sget-object v7, Lcom/glympse/platform/Platform;->m_oContext:Landroid/content/Context;

    const-string v8, "phone"

    invoke-virtual {v7, v8}, Landroid/content/Context;->getSystemService(Ljava/lang/String;)Ljava/lang/Object;

    move-result-object v6

    check-cast v6, Landroid/telephony/TelephonyManager;

    .line 706
    .local v6, oTelephonyManager:Landroid/telephony/TelephonyManager;
    invoke-virtual {v6}, Landroid/telephony/TelephonyManager;->getPhoneType()I

    move-result v1

    .line 707
    invoke-virtual {v6}, Landroid/telephony/TelephonyManager;->getSimState()I
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    move-result v2

    .line 716
    .end local v6           #oTelephonyManager:Landroid/telephony/TelephonyManager;
    :goto_0
    if-nez v5, :cond_0

    .line 717
    if-nez v3, :cond_0

    .line 718
    if-eqz v1, :cond_0

    .line 719
    if-eq v9, v2, :cond_0

    move v4, v9

    .line 721
    .local v4, fCanSendSms:Z
    :goto_1
    new-instance v7, Ljava/lang/StringBuilder;

    const-string v8, "DoesSupportSmsSending:"

    invoke-direct {v7, v8}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    invoke-virtual {v7, v4}, Ljava/lang/StringBuilder;->append(Z)Ljava/lang/StringBuilder;

    move-result-object v7

    .line 722
    const-string v8, " (Emulator:"

    invoke-virtual {v7, v8}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v7

    invoke-virtual {v7, v5}, Ljava/lang/StringBuilder;->append(Z)Ljava/lang/StringBuilder;

    move-result-object v7

    .line 723
    const-string v8, ", Airplane mode:"

    invoke-virtual {v7, v8}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v7

    invoke-virtual {v7, v3}, Ljava/lang/StringBuilder;->append(Z)Ljava/lang/StringBuilder;

    move-result-object v7

    .line 724
    const-string v8, ", Phone type :"

    invoke-virtual {v7, v8}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v7

    invoke-static {v1}, Lcom/glympse/platform/Platform;->GetTelephonyManagerPhoneTypeString(I)Ljava/lang/String;

    move-result-object v8

    invoke-virtual {v7, v8}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v7

    .line 725
    const-string v8, ", SIM state:"

    invoke-virtual {v7, v8}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v7

    invoke-static {v2}, Lcom/glympse/platform/Platform;->GetTelephonyManagerSimStateString(I)Ljava/lang/String;

    move-result-object v8

    invoke-virtual {v7, v8}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v7

    const-string v8, ")"

    invoke-virtual {v7, v8}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v7

    .line 721
    invoke-virtual {v7}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v7

    invoke-static {v7}, Lcom/glympse/platform/common/Helpers;->Log(Ljava/lang/String;)V

    .line 727
    return v4

    .line 709
    .end local v4           #fCanSendSms:Z
    :catch_0
    move-exception v7

    move-object v0, v7

    .line 711
    .local v0, e:Ljava/lang/Exception;
    invoke-static {v0}, Lcom/glympse/platform/common/Helpers;->Log(Ljava/lang/Throwable;)V

    goto :goto_0

    .line 719
    .end local v0           #e:Ljava/lang/Exception;
    :cond_0
    const/4 v7, 0x0

    move v4, v7

    goto :goto_1
.end method

.method public GetBrowserAgent()Ljava/lang/String;
    .locals 14

    .prologue
    const/4 v11, 0x0

    const/16 v13, 0xa

    .line 441
    invoke-static {}, Ljava/util/Locale;->getDefault()Ljava/util/Locale;

    move-result-object v4

    .line 442
    .local v4, oLocale:Ljava/util/Locale;
    if-nez v4, :cond_1

    move-object v8, v11

    .line 443
    .local v8, strLanguage:Ljava/lang/String;
    :goto_0
    if-nez v4, :cond_2

    move-object v7, v11

    .line 444
    .local v7, strCountry:Ljava/lang/String;
    :goto_1
    new-instance v10, Ljava/lang/StringBuilder;

    invoke-static {v8}, Lcom/glympse/platform/common/Helpers;->IsEmpty(Ljava/lang/String;)Z

    move-result v11

    if-eqz v11, :cond_3

    const-string v11, "??"

    :goto_2
    invoke-static {v11}, Ljava/lang/String;->valueOf(Ljava/lang/Object;)Ljava/lang/String;

    move-result-object v11

    invoke-direct {v10, v11}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    const-string v11, "-"

    invoke-virtual {v10, v11}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v10

    invoke-static {v7}, Lcom/glympse/platform/common/Helpers;->IsEmpty(Ljava/lang/String;)Z

    move-result v11

    if-eqz v11, :cond_4

    const-string v11, "??"

    :goto_3
    invoke-virtual {v10, v11}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v10

    invoke-virtual {v10}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v6

    .line 446
    .local v6, strCode:Ljava/lang/String;
    const/4 v9, 0x0

    .line 449
    .local v9, strTZ:Ljava/lang/String;
    :try_start_0
    invoke-static {}, Ljava/util/TimeZone;->getDefault()Ljava/util/TimeZone;

    move-result-object v10

    invoke-static {}, Lcom/glympse/platform/common/CorrectedTime;->GetTime()J

    move-result-wide v11

    invoke-virtual {v10, v11, v12}, Ljava/util/TimeZone;->getOffset(J)I

    move-result v3

    .line 450
    .local v3, nOffset:I
    invoke-static {v3}, Ljava/lang/Math;->abs(I)I

    move-result v10

    const v11, 0x15752a00

    if-ge v10, v11, :cond_0

    .line 452
    invoke-static {v3}, Ljava/lang/Math;->abs(I)I

    move-result v10

    const v11, 0x36ee80

    div-int v1, v10, v11

    .line 453
    .local v1, nHours:I
    invoke-static {v3}, Ljava/lang/Math;->abs(I)I

    move-result v10

    const v11, 0xea60

    div-int/2addr v10, v11

    rem-int/lit8 v2, v10, 0x3c

    .line 454
    .local v2, nMinutes:I
    new-instance v10, Ljava/lang/StringBuilder;

    if-gez v3, :cond_5

    const/16 v11, 0x2d

    :goto_4
    invoke-static {v11}, Ljava/lang/String;->valueOf(C)Ljava/lang/String;

    move-result-object v11

    invoke-direct {v10, v11}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    .line 455
    if-ge v1, v13, :cond_6

    const-string v11, "0"

    :goto_5
    invoke-virtual {v10, v11}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v10

    invoke-virtual {v10, v1}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    move-result-object v10

    .line 456
    if-ge v2, v13, :cond_7

    const-string v11, "0"

    :goto_6
    invoke-virtual {v10, v11}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v10

    invoke-virtual {v10, v2}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    move-result-object v10

    .line 454
    invoke-virtual {v10}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    move-result-object v9

    .line 467
    .end local v1           #nHours:I
    .end local v2           #nMinutes:I
    .end local v3           #nOffset:I
    :cond_0
    :goto_7
    new-instance v10, Ljava/lang/StringBuilder;

    const-string v11, "Glympse/1.28 (Android/"

    invoke-direct {v10, v11}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    .line 468
    invoke-static {}, Lcom/glympse/platform/Platform;->GetOsVer()Ljava/lang/String;

    move-result-object v11

    invoke-virtual {v10, v11}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v10

    .line 469
    const-string v11, "; "

    invoke-virtual {v10, v11}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v10

    invoke-virtual {v10, v6}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v10

    .line 470
    const-string v11, "; bt:"

    invoke-virtual {v10, v11}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v10

    const-string v11, "Android"

    invoke-virtual {v10, v11}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v10

    .line 471
    const-string v11, "; rv:"

    invoke-virtual {v10, v11}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v10

    const/16 v11, 0x82

    invoke-virtual {v10, v11}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    move-result-object v10

    .line 472
    const-string v11, "; p:"

    invoke-virtual {v10, v11}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v10

    const-string v11, "0.3"

    invoke-virtual {v10, v11}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v10

    .line 473
    const-string v11, "; bn:"

    invoke-virtual {v10, v11}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v10

    const-string v11, "as"

    invoke-virtual {v10, v11}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v10

    .line 474
    iget-object v11, p0, Lcom/glympse/platform/Platform;->m_oConfig:Lcom/glympse/platform/Config;

    iget-object v11, v11, Lcom/glympse/platform/Config;->m_strOriginalBuildName:Ljava/lang/String;

    invoke-static {v11}, Lcom/glympse/platform/common/Helpers;->IsEmpty(Ljava/lang/String;)Z

    move-result v11

    if-nez v11, :cond_8

    iget-object v11, p0, Lcom/glympse/platform/Platform;->m_oConfig:Lcom/glympse/platform/Config;

    iget-object v11, v11, Lcom/glympse/platform/Config;->m_strOriginalBuildName:Ljava/lang/String;

    const-string v12, "as"

    invoke-virtual {v11, v12}, Ljava/lang/String;->compareTo(Ljava/lang/String;)I

    move-result v11

    if-eqz v11, :cond_8

    .line 475
    new-instance v11, Ljava/lang/StringBuilder;

    const-string v12, "; obn:"

    invoke-direct {v11, v12}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    iget-object v12, p0, Lcom/glympse/platform/Platform;->m_oConfig:Lcom/glympse/platform/Config;

    iget-object v12, v12, Lcom/glympse/platform/Config;->m_strOriginalBuildName:Ljava/lang/String;

    invoke-virtual {v11, v12}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v11

    invoke-virtual {v11}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v11

    .line 474
    :goto_8
    invoke-virtual {v10, v11}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v10

    .line 476
    invoke-static {v9}, Lcom/glympse/platform/common/Helpers;->IsEmpty(Ljava/lang/String;)Z

    move-result v11

    if-eqz v11, :cond_9

    const-string v11, ""

    :goto_9
    invoke-virtual {v10, v11}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v10

    .line 477
    const-string v11, ")"

    invoke-virtual {v10, v11}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v10

    .line 467
    invoke-virtual {v10}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v5

    .line 479
    .local v5, strAgent:Ljava/lang/String;
    new-instance v10, Ljava/lang/StringBuilder;

    const-string v11, "Agent: "

    invoke-direct {v10, v11}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    invoke-virtual {v10, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v10

    invoke-virtual {v10}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v10

    invoke-static {v10}, Lcom/glympse/platform/common/Helpers;->Log(Ljava/lang/String;)V

    .line 481
    return-object v5

    .line 442
    .end local v5           #strAgent:Ljava/lang/String;
    .end local v6           #strCode:Ljava/lang/String;
    .end local v7           #strCountry:Ljava/lang/String;
    .end local v8           #strLanguage:Ljava/lang/String;
    .end local v9           #strTZ:Ljava/lang/String;
    :cond_1
    invoke-virtual {v4}, Ljava/util/Locale;->getLanguage()Ljava/lang/String;

    move-result-object v10

    move-object v8, v10

    goto/16 :goto_0

    .line 443
    .restart local v8       #strLanguage:Ljava/lang/String;
    :cond_2
    invoke-virtual {v4}, Ljava/util/Locale;->getCountry()Ljava/lang/String;

    move-result-object v10

    move-object v7, v10

    goto/16 :goto_1

    .restart local v7       #strCountry:Ljava/lang/String;
    :cond_3
    move-object v11, v8

    .line 444
    goto/16 :goto_2

    :cond_4
    move-object v11, v7

    goto/16 :goto_3

    .line 454
    .restart local v1       #nHours:I
    .restart local v2       #nMinutes:I
    .restart local v3       #nOffset:I
    .restart local v6       #strCode:Ljava/lang/String;
    .restart local v9       #strTZ:Ljava/lang/String;
    :cond_5
    const/16 v11, 0x2b

    goto/16 :goto_4

    .line 455
    :cond_6
    :try_start_1
    const-string v11, ""

    goto/16 :goto_5

    .line 456
    :cond_7
    const-string v11, ""
    :try_end_1
    .catch Ljava/lang/Exception; {:try_start_1 .. :try_end_1} :catch_0

    goto/16 :goto_6

    .line 459
    .end local v1           #nHours:I
    .end local v2           #nMinutes:I
    .end local v3           #nOffset:I
    :catch_0
    move-exception v10

    move-object v0, v10

    .line 461
    .local v0, e:Ljava/lang/Exception;
    invoke-static {v0}, Lcom/glympse/platform/common/Helpers;->Log(Ljava/lang/Throwable;)V

    goto/16 :goto_7

    .line 475
    .end local v0           #e:Ljava/lang/Exception;
    :cond_8
    const-string v11, ""

    goto :goto_8

    .line 476
    :cond_9
    new-instance v11, Ljava/lang/StringBuilder;

    const-string v12, "; tz:"

    invoke-direct {v11, v12}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    invoke-virtual {v11, v9}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v11

    invoke-virtual {v11}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v11

    goto :goto_9
.end method

.method public GetCannedMessages()[Ljava/lang/String;
    .locals 2

    .prologue
    .line 570
    sget-object v0, Lcom/glympse/platform/Platform;->m_oContext:Landroid/content/Context;

    invoke-virtual {v0}, Landroid/content/Context;->getResources()Landroid/content/res/Resources;

    move-result-object v0

    const/high16 v1, 0x7f07

    invoke-virtual {v0, v1}, Landroid/content/res/Resources;->getStringArray(I)[Ljava/lang/String;

    move-result-object v0

    return-object v0
.end method

.method public GetExtraPostData()Ljava/lang/String;
    .locals 8

    .prologue
    .line 487
    const-string v5, ""

    .line 492
    .local v5, strPost:Ljava/lang/String;
    :try_start_0
    sget-object v6, Landroid/os/Build;->BRAND:Ljava/lang/String;

    invoke-static {v6}, Lcom/glympse/platform/common/Helpers;->IsEmpty(Ljava/lang/String;)Z

    move-result v6

    if-nez v6, :cond_0

    .line 494
    new-instance v6, Ljava/lang/StringBuilder;

    invoke-static {v5}, Ljava/lang/String;->valueOf(Ljava/lang/Object;)Ljava/lang/String;

    move-result-object v7

    invoke-direct {v6, v7}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    invoke-virtual {v5}, Ljava/lang/String;->length()I

    move-result v7

    if-lez v7, :cond_4

    const-string v7, "&"

    :goto_0
    invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v6

    const-string v7, "BRAND="

    invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v6

    sget-object v7, Landroid/os/Build;->BRAND:Ljava/lang/String;

    invoke-static {v7}, Lcom/glympse/platform/Platform;->UrlEncode(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v7

    invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v6

    invoke-virtual {v6}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v5

    .line 498
    :cond_0
    sget-object v6, Landroid/os/Build;->MODEL:Ljava/lang/String;

    invoke-static {v6}, Lcom/glympse/platform/common/Helpers;->IsEmpty(Ljava/lang/String;)Z

    move-result v6

    if-nez v6, :cond_1

    .line 500
    new-instance v6, Ljava/lang/StringBuilder;

    invoke-static {v5}, Ljava/lang/String;->valueOf(Ljava/lang/Object;)Ljava/lang/String;

    move-result-object v7

    invoke-direct {v6, v7}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    invoke-virtual {v5}, Ljava/lang/String;->length()I

    move-result v7

    if-lez v7, :cond_5

    const-string v7, "&"

    :goto_1
    invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v6

    const-string v7, "MODEL="

    invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v6

    sget-object v7, Landroid/os/Build;->MODEL:Ljava/lang/String;

    invoke-static {v7}, Lcom/glympse/platform/Platform;->UrlEncode(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v7

    invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v6

    invoke-virtual {v6}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v5

    .line 504
    :cond_1
    sget-object v6, Lcom/glympse/platform/Platform;->m_oContext:Landroid/content/Context;

    const-string v7, "phone"

    invoke-virtual {v6, v7}, Landroid/content/Context;->getSystemService(Ljava/lang/String;)Ljava/lang/Object;

    move-result-object v3

    check-cast v3, Landroid/telephony/TelephonyManager;

    .line 505
    .local v3, oTelephonyManager:Landroid/telephony/TelephonyManager;
    if-eqz v3, :cond_3

    .line 510
    invoke-virtual {v3}, Landroid/telephony/TelephonyManager;->getPhoneType()I

    move-result v2

    .line 511
    .local v2, ePhoneType:I
    new-instance v6, Ljava/lang/StringBuilder;

    invoke-static {v5}, Ljava/lang/String;->valueOf(Ljava/lang/Object;)Ljava/lang/String;

    move-result-object v7

    invoke-direct {v6, v7}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    invoke-virtual {v5}, Ljava/lang/String;->length()I

    move-result v7

    if-lez v7, :cond_6

    const-string v7, "&"

    :goto_2
    invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v6

    const-string v7, "PHONE_TYPE="

    invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v6

    invoke-static {v2}, Lcom/glympse/platform/Platform;->GetTelephonyManagerPhoneTypeString(I)Ljava/lang/String;

    move-result-object v7

    invoke-static {v7}, Lcom/glympse/platform/Platform;->UrlEncode(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v7

    invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v6

    invoke-virtual {v6}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v5

    .line 514
    invoke-virtual {v3}, Landroid/telephony/TelephonyManager;->getNetworkType()I

    move-result v1

    .line 515
    .local v1, eNetworkType:I
    new-instance v6, Ljava/lang/StringBuilder;

    invoke-static {v5}, Ljava/lang/String;->valueOf(Ljava/lang/Object;)Ljava/lang/String;

    move-result-object v7

    invoke-direct {v6, v7}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    invoke-virtual {v5}, Ljava/lang/String;->length()I

    move-result v7

    if-lez v7, :cond_7

    const-string v7, "&"

    :goto_3
    invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v6

    const-string v7, "NET_TYPE="

    invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v6

    invoke-static {v1}, Lcom/glympse/platform/Platform;->GetTelephonyManagerNetworkTypeString(I)Ljava/lang/String;

    move-result-object v7

    invoke-static {v7}, Lcom/glympse/platform/Platform;->UrlEncode(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v7

    invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v6

    invoke-virtual {v6}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v5

    .line 518
    invoke-virtual {v3}, Landroid/telephony/TelephonyManager;->getSimOperatorName()Ljava/lang/String;

    move-result-object v4

    .line 519
    .local v4, str:Ljava/lang/String;
    invoke-static {v4}, Lcom/glympse/platform/common/Helpers;->IsEmpty(Ljava/lang/String;)Z

    move-result v6

    if-nez v6, :cond_2

    .line 521
    new-instance v6, Ljava/lang/StringBuilder;

    invoke-static {v5}, Ljava/lang/String;->valueOf(Ljava/lang/Object;)Ljava/lang/String;

    move-result-object v7

    invoke-direct {v6, v7}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    invoke-virtual {v5}, Ljava/lang/String;->length()I

    move-result v7

    if-lez v7, :cond_8

    const-string v7, "&"

    :goto_4
    invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v6

    const-string v7, "SIM_NAME="

    invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v6

    invoke-static {v4}, Lcom/glympse/platform/Platform;->UrlEncode(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v7

    invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v6

    invoke-virtual {v6}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v5

    .line 525
    :cond_2
    invoke-virtual {v3}, Landroid/telephony/TelephonyManager;->getNetworkOperatorName()Ljava/lang/String;

    move-result-object v4

    .line 526
    invoke-static {v4}, Lcom/glympse/platform/common/Helpers;->IsEmpty(Ljava/lang/String;)Z

    move-result v6

    if-nez v6, :cond_3

    .line 528
    new-instance v6, Ljava/lang/StringBuilder;

    invoke-static {v5}, Ljava/lang/String;->valueOf(Ljava/lang/Object;)Ljava/lang/String;

    move-result-object v7

    invoke-direct {v6, v7}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    invoke-virtual {v5}, Ljava/lang/String;->length()I

    move-result v7

    if-lez v7, :cond_9

    const-string v7, "&"

    :goto_5
    invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v6

    const-string v7, "NET_NAME="

    invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v6

    invoke-static {v4}, Lcom/glympse/platform/Platform;->UrlEncode(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v7

    invoke-virtual {v6, v7}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v6

    invoke-virtual {v6}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v5

    .line 537
    .end local v1           #eNetworkType:I
    .end local v2           #ePhoneType:I
    .end local v3           #oTelephonyManager:Landroid/telephony/TelephonyManager;
    .end local v4           #str:Ljava/lang/String;
    :cond_3
    :goto_6
    return-object v5

    .line 494
    :cond_4
    const-string v7, ""

    goto/16 :goto_0

    .line 500
    :cond_5
    const-string v7, ""

    goto/16 :goto_1

    .line 511
    .restart local v2       #ePhoneType:I
    .restart local v3       #oTelephonyManager:Landroid/telephony/TelephonyManager;
    :cond_6
    const-string v7, ""

    goto/16 :goto_2

    .line 515
    .restart local v1       #eNetworkType:I
    :cond_7
    const-string v7, ""

    goto/16 :goto_3

    .line 521
    .restart local v4       #str:Ljava/lang/String;
    :cond_8
    const-string v7, ""

    goto :goto_4

    .line 528
    :cond_9
    const-string v7, ""
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    goto :goto_5

    .line 532
    .end local v1           #eNetworkType:I
    .end local v2           #ePhoneType:I
    .end local v3           #oTelephonyManager:Landroid/telephony/TelephonyManager;
    .end local v4           #str:Ljava/lang/String;
    :catch_0
    move-exception v6

    move-object v0, v6

    .line 534
    .local v0, e:Ljava/lang/Exception;
    invoke-static {v0}, Lcom/glympse/platform/common/Helpers;->Log(Ljava/lang/Throwable;)V

    goto :goto_6
.end method

.method public GetFromNumber()Ljava/lang/String;
    .locals 4

    .prologue
    .line 751
    :try_start_0
    sget-object v2, Lcom/glympse/platform/Platform;->m_oContext:Landroid/content/Context;

    const-string v3, "phone"

    invoke-virtual {v2, v3}, Landroid/content/Context;->getSystemService(Ljava/lang/String;)Ljava/lang/Object;

    move-result-object v1

    check-cast v1, Landroid/telephony/TelephonyManager;

    .line 752
    .local v1, oTelephonyManager:Landroid/telephony/TelephonyManager;
    invoke-virtual {v1}, Landroid/telephony/TelephonyManager;->getLine1Number()Ljava/lang/String;
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    move-result-object v2

    .line 758
    .end local v1           #oTelephonyManager:Landroid/telephony/TelephonyManager;
    :goto_0
    return-object v2

    .line 754
    :catch_0
    move-exception v2

    move-object v0, v2

    .line 756
    .local v0, e:Ljava/lang/Exception;
    invoke-static {v0}, Lcom/glympse/platform/common/Helpers;->Log(Ljava/lang/Throwable;)V

    .line 758
    const/4 v2, 0x0

    goto :goto_0
.end method

.method public IsAirplaneMode()Z
    .locals 4

    .prologue
    const/4 v3, 0x0

    .line 735
    :try_start_0
    sget-object v0, Lcom/glympse/platform/Platform;->m_oContext:Landroid/content/Context;

    invoke-virtual {v0}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;

    move-result-object v0

    const-string v1, "airplane_mode_on"

    const/4 v2, 0x0

    invoke-static {v0, v1, v2}, Landroid/provider/Settings$System;->getInt(Landroid/content/ContentResolver;Ljava/lang/String;I)I
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    move-result v0

    if-eqz v0, :cond_0

    const/4 v0, 0x1

    .line 740
    :goto_0
    return v0

    :cond_0
    move v0, v3

    .line 735
    goto :goto_0

    .line 737
    :catch_0
    move-exception v0

    move v0, v3

    .line 740
    goto :goto_0
.end method

.method public PlaySound(Ljava/lang/String;)V
    .locals 6
    .parameter "strResource"

    .prologue
    .line 1099
    :try_start_0
    new-instance v1, Landroid/app/Notification;

    invoke-direct {v1}, Landroid/app/Notification;-><init>()V

    .line 1100
    .local v1, oNotification:Landroid/app/Notification;
    const/4 v2, 0x4

    iput v2, v1, Landroid/app/Notification;->defaults:I

    .line 1101
    const/16 v2, 0x8

    new-array v2, v2, [J

    const/4 v3, 0x1

    const-wide/16 v4, 0x32

    aput-wide v4, v2, v3

    const/4 v3, 0x2

    const-wide/16 v4, 0x1e

    aput-wide v4, v2, v3

    const/4 v3, 0x3

    const-wide/16 v4, 0x32

    aput-wide v4, v2, v3

    const/4 v3, 0x4

    const-wide/16 v4, 0x46

    aput-wide v4, v2, v3

    const/4 v3, 0x5

    const-wide/16 v4, 0x32

    aput-wide v4, v2, v3

    const/4 v3, 0x6

    const-wide/16 v4, 0x1e

    aput-wide v4, v2, v3

    const/4 v3, 0x7

    const-wide/16 v4, 0x32

    aput-wide v4, v2, v3

    iput-object v2, v1, Landroid/app/Notification;->vibrate:[J

    .line 1102
    new-instance v2, Ljava/lang/StringBuilder;

    const-string v3, "android.resource://com.glympse.android.glympse/raw/"

    invoke-direct {v2, v3}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    invoke-virtual {v2, p1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v2

    invoke-virtual {v2}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v2

    invoke-static {v2}, Landroid/net/Uri;->parse(Ljava/lang/String;)Landroid/net/Uri;

    move-result-object v2

    iput-object v2, v1, Landroid/app/Notification;->sound:Landroid/net/Uri;

    .line 1103
    sget-object v2, Lcom/glympse/platform/Platform;->m_oContext:Landroid/content/Context;

    const-string v3, "notification"

    invoke-virtual {v2, v3}, Landroid/content/Context;->getSystemService(Ljava/lang/String;)Ljava/lang/Object;

    move-result-object p0

    .end local p0
    check-cast p0, Landroid/app/NotificationManager;

    const/16 v2, 0x378

    invoke-virtual {p0, v2, v1}, Landroid/app/NotificationManager;->notify(ILandroid/app/Notification;)V
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    .line 1109
    .end local v1           #oNotification:Landroid/app/Notification;
    :goto_0
    return-void

    .line 1105
    :catch_0
    move-exception v2

    move-object v0, v2

    .line 1107
    .local v0, e:Ljava/lang/Exception;
    invoke-static {v0}, Lcom/glympse/platform/common/Helpers;->Log(Ljava/lang/Throwable;)V

    goto :goto_0
.end method

.method public PostToMainThread(Lcom/glympse/platform/GRunnable;)Z
    .locals 1
    .parameter "oRunnable"

    .prologue
    .line 844
    iget-object v0, p0, Lcom/glympse/platform/Platform;->m_oHandler:Landroid/os/Handler;

    invoke-virtual {v0, p1}, Landroid/os/Handler;->post(Ljava/lang/Runnable;)Z

    move-result v0

    return v0
.end method

.method public PostToMainThreadDelayed(Lcom/glympse/platform/GRunnable;J)Z
    .locals 1
    .parameter "oRunnable"
    .parameter "lDelayMs"

    .prologue
    .line 861
    iget-object v0, p0, Lcom/glympse/platform/Platform;->m_oHandler:Landroid/os/Handler;

    invoke-virtual {v0, p1, p2, p3}, Landroid/os/Handler;->postDelayed(Ljava/lang/Runnable;J)Z

    move-result v0

    return v0
.end method

.method public PostToMainThreadIfNeeded(Lcom/glympse/platform/GRunnable;)Z
    .locals 1
    .parameter "oRunnable"

    .prologue
    .line 850
    invoke-virtual {p0}, Lcom/glympse/platform/Platform;->IsMainThread()Z

    move-result v0

    if-eqz v0, :cond_0

    .line 852
    invoke-virtual {p1}, Lcom/glympse/platform/GRunnable;->Run()V

    .line 853
    const/4 v0, 0x1

    .line 855
    :goto_0
    return v0

    :cond_0
    invoke-virtual {p0, p1}, Lcom/glympse/platform/Platform;->PostToMainThread(Lcom/glympse/platform/GRunnable;)Z

    move-result v0

    goto :goto_0
.end method

.method public ScanSmsInbox()V
    .locals 15

    .prologue
    .line 935
    iget-object v0, p0, Lcom/glympse/platform/Platform;->m_oSmsReceiver:Lcom/glympse/platform/SmsReceiver;

    if-nez v0, :cond_0

    .line 939
    :try_start_0
    new-instance v0, Lcom/glympse/platform/SmsReceiver;

    invoke-direct {v0}, Lcom/glympse/platform/SmsReceiver;-><init>()V

    iput-object v0, p0, Lcom/glympse/platform/Platform;->m_oSmsReceiver:Lcom/glympse/platform/SmsReceiver;

    .line 940
    sget-object v0, Lcom/glympse/platform/Platform;->m_oContext:Landroid/content/Context;

    iget-object v1, p0, Lcom/glympse/platform/Platform;->m_oSmsReceiver:Lcom/glympse/platform/SmsReceiver;

    new-instance v2, Landroid/content/IntentFilter;

    const-string v3, "android.provider.Telephony.SMS_RECEIVED"

    invoke-direct {v2, v3}, Landroid/content/IntentFilter;-><init>(Ljava/lang/String;)V

    invoke-virtual {v0, v1, v2}, Landroid/content/Context;->registerReceiver(Landroid/content/BroadcastReceiver;Landroid/content/IntentFilter;)Landroid/content/Intent;
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    .line 948
    :cond_0
    :goto_0
    const/4 v12, 0x0

    .line 950
    .local v12, oCursor:Landroid/database/Cursor;
    new-instance v11, Lcom/glympse/platform/GVector$Longs;

    invoke-direct {v11}, Lcom/glympse/platform/GVector$Longs;-><init>()V

    .line 951
    .local v11, listTicketIds:Lcom/glympse/platform/GVector$Longs;,"Lcom/glympse/platform/GVector$Longs;"
    const-wide/16 v7, 0x0

    .line 956
    .local v7, lLatestTime:J
    :try_start_1
    sget-object v0, Lcom/glympse/platform/Platform;->m_oContext:Landroid/content/Context;

    invoke-virtual {v0}, Landroid/content/Context;->getContentResolver()Landroid/content/ContentResolver;

    move-result-object v0

    .line 957
    const-string v1, "content://sms"

    invoke-static {v1}, Landroid/net/Uri;->parse(Ljava/lang/String;)Landroid/net/Uri;

    move-result-object v1

    const-string v2, "inbox"

    invoke-static {v1, v2}, Landroid/net/Uri;->withAppendedPath(Landroid/net/Uri;Ljava/lang/String;)Landroid/net/Uri;

    move-result-object v1

    .line 958
    const/4 v2, 0x2

    new-array v2, v2, [Ljava/lang/String;

    const/4 v3, 0x0

    const-string v4, "date"

    aput-object v4, v2, v3

    const/4 v3, 0x1

    const-string v4, "body"

    aput-object v4, v2, v3

    .line 959
    new-instance v3, Ljava/lang/StringBuilder;

    const-string v4, "date > "

    invoke-direct {v3, v4}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    iget-object v4, p0, Lcom/glympse/platform/Platform;->m_oConfig:Lcom/glympse/platform/Config;

    iget-wide v4, v4, Lcom/glympse/platform/Config;->m_lLastScannedSmsTime:J

    invoke-virtual {v3, v4, v5}, Ljava/lang/StringBuilder;->append(J)Ljava/lang/StringBuilder;

    move-result-object v3

    invoke-virtual {v3}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v3

    .line 960
    const/4 v4, 0x0

    const/4 v5, 0x0

    .line 956
    invoke-virtual/range {v0 .. v5}, Landroid/content/ContentResolver;->query(Landroid/net/Uri;[Ljava/lang/String;Ljava/lang/String;[Ljava/lang/String;Ljava/lang/String;)Landroid/database/Cursor;

    move-result-object v12

    .line 963
    invoke-interface {v12}, Landroid/database/Cursor;->moveToFirst()Z

    move-result v0

    if-eqz v0, :cond_4

    .line 969
    :cond_1
    const/4 v0, 0x0

    invoke-interface {v12, v0}, Landroid/database/Cursor;->getLong(I)J

    move-result-wide v9

    .line 970
    .local v9, lTime:J
    const/4 v0, 0x1

    invoke-interface {v12, v0}, Landroid/database/Cursor;->getString(I)Ljava/lang/String;

    move-result-object v14

    .line 973
    .local v14, strBody:Ljava/lang/String;
    cmp-long v0, v9, v7

    if-lez v0, :cond_2

    .line 975
    move-wide v7, v9

    .line 979
    :cond_2
    new-instance v13, Lcom/glympse/platform/common/UrlParser;

    invoke-direct {v13}, Lcom/glympse/platform/common/UrlParser;-><init>()V

    .line 980
    .local v13, oUrlParser:Lcom/glympse/platform/common/UrlParser;
    const/4 v0, 0x1

    invoke-virtual {v13, v14, v0}, Lcom/glympse/platform/common/UrlParser;->ParseUrls(Ljava/lang/String;Z)Z

    .line 981
    iget-object v0, v13, Lcom/glympse/platform/common/UrlParser;->m_listTicketIds:Lcom/glympse/platform/GVector$Longs;

    if-eqz v0, :cond_3

    .line 983
    iget-object v0, v13, Lcom/glympse/platform/common/UrlParser;->m_listTicketIds:Lcom/glympse/platform/GVector$Longs;

    invoke-virtual {v11, v0}, Lcom/glympse/platform/GVector$Longs;->addAll(Ljava/util/Collection;)Z

    .line 986
    :cond_3
    invoke-interface {v12}, Landroid/database/Cursor;->moveToNext()Z
    :try_end_1
    .catchall {:try_start_1 .. :try_end_1} :catchall_0
    .catch Ljava/lang/Exception; {:try_start_1 .. :try_end_1} :catch_1

    move-result v0

    .line 966
    if-nez v0, :cond_1

    .line 996
    .end local v9           #lTime:J
    .end local v13           #oUrlParser:Lcom/glympse/platform/common/UrlParser;
    .end local v14           #strBody:Ljava/lang/String;
    :cond_4
    if-eqz v12, :cond_5

    .line 998
    invoke-interface {v12}, Landroid/database/Cursor;->close()V

    .line 999
    const/4 v12, 0x0

    .line 1004
    :cond_5
    :goto_1
    iget-object v0, p0, Lcom/glympse/platform/Platform;->m_oServerPost:Lcom/glympse/platform/common/ServerPost;

    invoke-virtual {v0, v11, v7, v8}, Lcom/glympse/platform/common/ServerPost;->AddReceivedSmsTickets(Lcom/glympse/platform/GVector$Longs;J)Z

    .line 1005
    return-void

    .line 942
    .end local v7           #lLatestTime:J
    .end local v11           #listTicketIds:Lcom/glympse/platform/GVector$Longs;,"Lcom/glympse/platform/GVector$Longs;"
    .end local v12           #oCursor:Landroid/database/Cursor;
    :catch_0
    move-exception v0

    move-object v6, v0

    .line 944
    .local v6, e:Ljava/lang/Exception;
    invoke-static {v6}, Lcom/glympse/platform/common/Helpers;->Log(Ljava/lang/Throwable;)V

    goto :goto_0

    .line 989
    .end local v6           #e:Ljava/lang/Exception;
    .restart local v7       #lLatestTime:J
    .restart local v11       #listTicketIds:Lcom/glympse/platform/GVector$Longs;,"Lcom/glympse/platform/GVector$Longs;"
    .restart local v12       #oCursor:Landroid/database/Cursor;
    :catch_1
    move-exception v0

    move-object v6, v0

    .line 991
    .restart local v6       #e:Ljava/lang/Exception;
    :try_start_2
    invoke-static {v6}, Lcom/glympse/platform/common/Helpers;->Log(Ljava/lang/Throwable;)V
    :try_end_2
    .catchall {:try_start_2 .. :try_end_2} :catchall_0

    .line 996
    if-eqz v12, :cond_5

    .line 998
    invoke-interface {v12}, Landroid/database/Cursor;->close()V

    .line 999
    const/4 v12, 0x0

    goto :goto_1

    .line 994
    .end local v6           #e:Ljava/lang/Exception;
    :catchall_0
    move-exception v0

    .line 996
    if-eqz v12, :cond_6

    .line 998
    invoke-interface {v12}, Landroid/database/Cursor;->close()V

    .line 999
    const/4 v12, 0x0

    .line 1001
    :cond_6
    throw v0
.end method

.method public SendSms(Lcom/glympse/platform/common/Recipient;Ljava/lang/String;Ljava/lang/String;)Z
    .locals 12
    .parameter "oRecipient"
    .parameter "strNumber"
    .parameter "strMessage"

    .prologue
    const/4 v11, 0x0

    .line 778
    invoke-static {}, Lcom/glympse/platform/Reflection$_SmsManager;->Load()Z

    move-result v1

    if-nez v1, :cond_0

    move v1, v11

    .line 838
    :goto_0
    return v1

    .line 787
    :cond_0
    :try_start_0
    invoke-static {}, Lcom/glympse/platform/Reflection$_SmsManager;->getDefault()Ljava/lang/Object;

    move-result-object v0

    .line 789
    .local v0, oSmsManager:Ljava/lang/Object;
    new-instance v1, Ljava/lang/StringBuilder;

    const-string v2, "SMS CLASS: ["

    invoke-direct {v1, v2}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    invoke-virtual {v0}, Ljava/lang/Object;->getClass()Ljava/lang/Class;

    move-result-object v2

    invoke-virtual {v2}, Ljava/lang/Class;->toString()Ljava/lang/String;

    move-result-object v2

    invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v1

    const-string v2, "]"

    invoke-virtual {v1, v2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v1

    invoke-virtual {v1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v1

    invoke-static {v1}, Lcom/glympse/platform/common/Helpers;->Log(Ljava/lang/String;)V

    .line 800
    invoke-static {v0, p3}, Lcom/glympse/platform/Reflection$_SmsManager;->divideMessage(Ljava/lang/Object;Ljava/lang/String;)Ljava/util/ArrayList;

    move-result-object v3

    .line 801
    .local v3, listParts:Ljava/util/ArrayList;,"Ljava/util/ArrayList<Ljava/lang/String;>;"
    new-instance v4, Ljava/util/ArrayList;

    invoke-virtual {v3}, Ljava/util/ArrayList;->size()I

    move-result v1

    invoke-direct {v4, v1}, Ljava/util/ArrayList;-><init>(I)V

    .line 805
    .local v4, listIntentsSent:Ljava/util/ArrayList;,"Ljava/util/ArrayList<Landroid/app/PendingIntent;>;"
    const/4 v7, 0x0

    .line 806
    .local v7, nPart:I
    invoke-virtual {v3}, Ljava/util/ArrayList;->iterator()Ljava/util/Iterator;

    move-result-object v1

    :goto_1
    invoke-interface {v1}, Ljava/util/Iterator;->hasNext()Z

    move-result v2

    if-nez v2, :cond_1

    .line 826
    const/4 v1, 0x3

    iput v1, p1, Lcom/glympse/platform/common/Recipient;->m_eSendState:I

    .line 829
    const/4 v2, 0x0

    const/4 v5, 0x0

    move-object v1, p2

    invoke-static/range {v0 .. v5}, Lcom/glympse/platform/Reflection$_SmsManager;->sendMultipartTextMessage(Ljava/lang/Object;Ljava/lang/String;Ljava/lang/String;Ljava/util/ArrayList;Ljava/util/ArrayList;Ljava/util/ArrayList;)V

    .line 831
    const/4 v1, 0x1

    goto :goto_0

    .line 806
    :cond_1
    invoke-interface {v1}, Ljava/util/Iterator;->next()Ljava/lang/Object;

    move-result-object v9

    check-cast v9, Ljava/lang/String;

    .line 808
    .local v9, strPart:Ljava/lang/String;
    new-instance v2, Ljava/lang/StringBuilder;

    const-string v5, "SMS PART #"

    invoke-direct {v2, v5}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    add-int/lit8 v5, v7, 0x1

    invoke-virtual {v2, v5}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    move-result-object v2

    const-string v5, ": "

    invoke-virtual {v2, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v2

    invoke-virtual {v9}, Ljava/lang/String;->length()I

    move-result v5

    invoke-virtual {v2, v5}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    move-result-object v2

    const-string v5, ", UTF7: "

    invoke-virtual {v2, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v2

    invoke-static {v9}, Lcom/glympse/platform/Platform;->IsUTF7(Ljava/lang/String;)Z

    move-result v5

    invoke-virtual {v2, v5}, Ljava/lang/StringBuilder;->append(Z)Ljava/lang/StringBuilder;

    move-result-object v2

    invoke-virtual {v2}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v2

    invoke-static {v2}, Lcom/glympse/platform/common/Helpers;->Log(Ljava/lang/String;)V

    .line 811
    new-instance v8, Landroid/content/Intent;

    new-instance v2, Ljava/lang/StringBuilder;

    const-string v5, "com.glympse.android.glympse.SMS_SENT_"

    invoke-direct {v2, v5}, Ljava/lang/StringBuilder;-><init>(Ljava/lang/String;)V

    invoke-virtual {p1}, Ljava/lang/Object;->hashCode()I

    move-result v5

    invoke-virtual {v2, v5}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    move-result-object v2

    const-string v5, "_"

    invoke-virtual {v2, v5}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    move-result-object v2

    invoke-virtual {v2, v7}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    move-result-object v2

    invoke-virtual {v2}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v2

    invoke-direct {v8, v2}, Landroid/content/Intent;-><init>(Ljava/lang/String;)V

    .line 815
    .local v8, oIntentSent:Landroid/content/Intent;
    sget-object v2, Lcom/glympse/platform/Platform;->m_oContext:Landroid/content/Context;

    const/4 v5, 0x0

    const/4 v10, 0x0

    invoke-static {v2, v5, v8, v10}, Landroid/app/PendingIntent;->getBroadcast(Landroid/content/Context;ILandroid/content/Intent;I)Landroid/app/PendingIntent;

    move-result-object v2

    invoke-virtual {v4, v2}, Ljava/util/ArrayList;->add(Ljava/lang/Object;)Z

    .line 819
    new-instance v2, Lcom/glympse/platform/Platform$SmsBroadcastReceiver;

    invoke-virtual {v8}, Landroid/content/Intent;->getAction()Ljava/lang/String;

    move-result-object v5

    const/4 v10, 0x0

    invoke-direct {v2, p0, p1, v5, v10}, Lcom/glympse/platform/Platform$SmsBroadcastReceiver;-><init>(Lcom/glympse/platform/Platform;Lcom/glympse/platform/common/Recipient;Ljava/lang/String;Ljava/lang/String;)V
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    .line 822
    add-int/lit8 v7, v7, 0x1

    goto :goto_1

    .line 833
    .end local v0           #oSmsManager:Ljava/lang/Object;
    .end local v3           #listParts:Ljava/util/ArrayList;,"Ljava/util/ArrayList<Ljava/lang/String;>;"
    .end local v4           #listIntentsSent:Ljava/util/ArrayList;,"Ljava/util/ArrayList<Landroid/app/PendingIntent;>;"
    .end local v7           #nPart:I
    .end local v8           #oIntentSent:Landroid/content/Intent;
    .end local v9           #strPart:Ljava/lang/String;
    :catch_0
    move-exception v1

    move-object v6, v1

    .line 835
    .local v6, e:Ljava/lang/Exception;
    invoke-static {v6}, Lcom/glympse/platform/common/Helpers;->Log(Ljava/lang/Throwable;)V

    move v1, v11

    .line 838
    goto/16 :goto_0
.end method

.method public ShowArrivalNotification()V
    .locals 4

    .prologue
    .line 1023
    new-instance v0, Lcom/glympse/platform/Platform$GToast;

    const v1, 0x7f020089

    const v2, 0x7f0a0098

    const/16 v3, 0x1770

    invoke-direct {v0, p0, v1, v2, v3}, Lcom/glympse/platform/Platform$GToast;-><init>(Lcom/glympse/platform/Platform;III)V

    .line 1024
    return-void
.end method

.method public ShowLowBatteryNotification()V
    .locals 4

    .prologue
    .line 1016
    new-instance v0, Lcom/glympse/platform/Platform$GToast;

    const v1, 0x7f02008a

    const v2, 0x7f0a0099

    const/16 v3, 0x1b58

    invoke-direct {v0, p0, v1, v2, v3}, Lcom/glympse/platform/Platform$GToast;-><init>(Lcom/glympse/platform/Platform;III)V

    .line 1017
    const-string v0, "low_battery"

    invoke-virtual {p0, v0}, Lcom/glympse/platform/Platform;->PlaySound(Ljava/lang/String;)V

    .line 1018
    return-void
.end method

.method public SignIn()V
    .locals 2

    .prologue
    .line 209
    iget-boolean v0, p0, Lcom/glympse/platform/Platform;->m_fSigninCalled:Z

    .line 211
    .local v0, m_fSigninCalledBefore:Z
    invoke-super {p0}, Lcom/glympse/platform/common/PlatformBase;->SignIn()V

    .line 213
    if-nez v0, :cond_0

    .line 215
    new-instance v1, Lcom/glympse/platform/Platform$BatteryBroadcastReceiver;

    invoke-direct {v1, p0}, Lcom/glympse/platform/Platform$BatteryBroadcastReceiver;-><init>(Lcom/glympse/platform/Platform;)V

    iput-object v1, p0, Lcom/glympse/platform/Platform;->m_oBatteryBroadcastReceiver:Lcom/glympse/platform/Platform$BatteryBroadcastReceiver;

    .line 217
    :cond_0
    return-void
.end method

.method public SignOut()V
    .locals 3

    .prologue
    const/4 v2, 0x0

    .line 222
    iget-object v0, p0, Lcom/glympse/platform/Platform;->m_oSmsReceiver:Lcom/glympse/platform/SmsReceiver;

    if-eqz v0, :cond_0

    .line 224
    sget-object v0, Lcom/glympse/platform/Platform;->m_oContext:Landroid/content/Context;

    iget-object v1, p0, Lcom/glympse/platform/Platform;->m_oSmsReceiver:Lcom/glympse/platform/SmsReceiver;

    invoke-virtual {v0, v1}, Landroid/content/Context;->unregisterReceiver(Landroid/content/BroadcastReceiver;)V

    .line 225
    iput-object v2, p0, Lcom/glympse/platform/Platform;->m_oSmsReceiver:Lcom/glympse/platform/SmsReceiver;

    .line 228
    :cond_0
    iget-boolean v0, p0, Lcom/glympse/platform/Platform;->m_fSigninCalled:Z

    if-eqz v0, :cond_1

    .line 230
    iget-object v0, p0, Lcom/glympse/platform/Platform;->m_oBatteryBroadcastReceiver:Lcom/glympse/platform/Platform$BatteryBroadcastReceiver;

    invoke-static {v0}, Lcom/glympse/platform/Platform$BatteryBroadcastReceiver;->access$0(Lcom/glympse/platform/Platform$BatteryBroadcastReceiver;)V

    .line 231
    iput-object v2, p0, Lcom/glympse/platform/Platform;->m_oBatteryBroadcastReceiver:Lcom/glympse/platform/Platform$BatteryBroadcastReceiver;

    .line 237
    :cond_1
    invoke-super {p0}, Lcom/glympse/platform/common/PlatformBase;->SignOut()V

    .line 238
    return-void
.end method

.method protected finalize()V
    .locals 1
    .annotation system Ldalvik/annotation/Throws;
        value = {
            Ljava/lang/Throwable;
        }
    .end annotation

    .prologue
    .line 166
    const-string v0, "Platform::finalize"

    invoke-static {v0}, Lcom/glympse/platform/common/Helpers;->Log(Ljava/lang/String;)V

    .line 168
    invoke-super {p0}, Ljava/lang/Object;->finalize()V

    .line 170
    sget-object v0, Lcom/glympse/platform/Platform;->ms_oThis:Lcom/glympse/platform/Platform;

    if-ne v0, p0, :cond_0

    .line 172
    const/4 v0, 0x0

    sput-object v0, Lcom/glympse/platform/Platform;->ms_oThis:Lcom/glympse/platform/Platform;

    .line 174
    :cond_0
    return-void
.end method
